<layout name="layout"/>
<div class="form-div search_form_div" style="float: right; margin-right: 100px;">

    <p><input id="goadd" type="button" value=" 添加基础配置 " class="button"/></p>

</div>
<!-- 列表 -->
<div class="list-div" id="listDiv">
    <table class="table table-hover text-center">
        <tr>
            <th>默认主机名</th>
            <th>短网址编码</th>
            <th width="300">操作</th>
        </tr>
        <?php foreach ($data as $k => $v): ?>
        <tr class="tron">
            <td><?php echo $v['zym']; ?></td>
            <td><?php echo $v['dwz']; ?></td>
            <td align="center">
                <a href="<?php echo U('edit?id='.$v['id'].'&p='.I('get.p')); ?>" title="编辑"
                   class="button border-main" style="cursor: pointer" ><span class="icon-edit"></span>编辑</a>
            </td>
        </tr>
        <?php endforeach; ?>
        <?php if(preg_match('/\d/', $page)): ?>
        <tr>
            <td colspan="10">
                <?php echo $page; ?>
            </td>
        </tr>
        <?php endif; ?>
    </table>
</div>

<script>
    $("#goadd").click(function () {
        location.href = "<?php echo U('config/add')?>";
    })
</script>